	<!-- BEGIN header -->
	<include file="public:header" />
	<!-- END header -->

	<!-- BEGIN CONTAINER -->

	<div class="page-container row-fluid">
		{$left_menu}
		<!-- BEGIN PAGE -->

		<div class="page-content">

			

			<!-- BEGIN PAGE CONTAINER-->        

			<div class="container-fluid">

				<!-- BEGIN PAGE HEADER-->

				<div class="row-fluid">

					<div class="span12">

						<!-- BEGIN STYLE CUSTOMIZER -->

						<!-- END BEGIN STYLE CUSTOMIZER -->  

						<!-- BEGIN PAGE TITLE & BREADCRUMB-->

						<!-- BEGIN PAGE TITLE & BREADCRUMB-->
						<include file="public:breadcrumb" />
						<!-- END PAGE TITLE & BREADCRUMB-->
						
						<!-- BEGIN sub_menu -->
						<include file="public:sub_menu" />
						<!-- END sub_menu -->

					</div>

				</div>

				<!-- END PAGE HEADER-->

				<!-- BEGIN PAGE CONTENT-->
				<div class="row-fluid">

					<div class="span12">

						<!-- BEGIN VALIDATION STATES-->

						<div class="portlet box blue">

							<div class="portlet-title">

								<div class="caption"><i class="icon-reorder"></i>站点设置</div>

								<div class="tools">

									<a href="javascript:;" class="collapse"></a>

								</div>

							</div>

							<div class="portlet-body form">

								<!-- BEGIN FORM-->

								<form action="{:U(MODULE_NAME.'/edit',array('menuid'=>$_GET['menuid'],'menupid'=>$_GET['menupid']))}" method="post" id="form_sample_1" class="form-horizontal" novalidate="novalidate">

									<volist name="list" id="v">
										<div class="control-group">
											<label class="control-label">{$v.remark}</label>
											 <eq name="v['stype']" value="1">
											<div class="controls">

												<input name="setting[{$v.name}]" class="span6 m-wrap" type="text" value="{:C('zyb_'.$v['name'])}">

											
											</eq>
											<eq name="v['stype']" value="2">
											<div class="controls">

												<input name="setting[{$v.name}]" class="span6 m-wrap" type="text" value="{:C('zyb_'.$v['name'])}">

											
											</eq>
											 <eq name="v['stype']" value="3">
											 <div class="controls">
												<textarea rows="3" class="span6 m-wrap"  name="setting[{$v.name}]">{:C('zyb_'.$v['name'])}</textarea>
											</eq>
											<eq name="v['stype']" value="4">
											<div class="controls">

												<label class="radio">

												<input name="setting[{$v.name}]" value="1" type="radio" <if condition="C('zyb_'.$v['name']) eq 1"> checked="checked"</if>>

												是

												</label>

												<label class="radio">

												<input name="setting[{$v.name}]" value="0" type="radio" <if condition="C('zyb_'.$v['name']) eq 0"> checked="checked"</if>>

												否

												</label> 
												
											</eq>
											<eq name="v['stype']" value="5"><?php $img=C('zyb_'.$v['name']); ?>
											
											<?php $has_img=1 ?>
											<div class="controls attachment_icon">
												  <input type="text" name="setting[{$v.name}]" value="<notempty name="img">{$img}</notempty>">
												  <img src="<empty name="img">./media/image/animated-overlay.gif<else />{$img}</empty>" class="img-thumbnail brandico kindeditor">
												  <div class="attachment_tip">
														<img src="">
												  </div>
											</eq>
											
											<span class="help-inline">{$v.name}</span>
											</div>
										</div>
									</volist>
									<input type="hidden" name="menuid"  value="{$menuid}"/>
									

									<div class="form-actions">

										<button type="submit" class="btn blue">设置</button>

										<a href="javascript:history.go(-1)" type="button" class="btn">取消</a>

									</div>

								</form>

								<!-- END FORM-->

							</div>

						</div>

						<!-- END VALIDATION STATES-->

					</div>

				</div>
				

				

				<!-- END PAGE CONTENT-->

			</div>

			<!-- END PAGE CONTAINER-->

		</div>

		<!-- END PAGE -->

	</div>

	<!-- END CONTAINER -->
	
	<!-- BEGIN FOOTER -->
	<include file="public:footer" />
	<!-- END FOOTER -->
	<if condition="$has_img eq 1">
	<style>
	.kindeditor {
		width: 50px;
		height: 50px;
	}
	.attachment_icon {
		margin-left: 8px;
		position: relative;
	}
	.attachment_tip {
		display: none;
		left: 16px;
		padding: 1px;
		position: absolute;
		top: 16px;
		z-index: 9;
	}
	</style>
	<link rel="stylesheet" href="./edit/themes/default/default.css" />
	<script charset="utf-8" src="./edit/kindeditor-min.js"></script>
	<script charset="utf-8" src="./edit/lang/zh_CN.js"></script>
	<script>
	
	KindEditor.ready(function(K) {
			var editor = K.editor({
					allowFileManager : true
			});
			$('.kindeditor').click(function() {
				var obj = $(this);
					editor.loadPlugin('image', function() {
							editor.plugin.imageDialog({
									imageUrl : obj.prev().val(),
									clickFn : function(url, title, width, height, border, align) {
											obj.prev().val(url);
											obj.attr("src",url);
											editor.hideDialog();
									}
							});
					});
			});
	});
	$(function(){
		$('.kindeditor').mouseover(function(){
			var img = $(this).prev().val();
			$(this).next().children().eq(0).attr('src',img);
			$(this).next().show();
			
		});
		$('.attachment_tip').click(function(){
			$(this).hide();
			
		});
	});	
    </script>
	
	</if>
</html>